package com.yuxi.Dao.Impl;

import java.io.Serializable;
import java.util.List;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Repository;

import com.yuxi.Dao.PositionDao;

import com.yuxi.Entity.Position;

@Repository
public class PositionDaoImpl extends BaseDaoImpl<Serializable, Serializable> implements PositionDao {
	
	private Logger logger=LoggerFactory.getLogger(PositionDaoImpl.class);
	public PositionDaoImpl(){
		super(Position.class);
	}
	
	@Override
	public Position getPosition(Integer positionId) {
		// TODO Auto-generated method stub
		return (Position) super.get(positionId);
	}

	@Override
	public Position addPosition(Position position) {
		// TODO Auto-generated method stub
		return (Position) addAndReturn(position);
	}

	@Override
	public void deletePosition(Position position) {
		// TODO Auto-generated method stub
		super.delete(position);
	}	

	@Override
	public void modifly(Position position) {
		// TODO Auto-generated method stub
		super.update(position);
	}

	@Override
	public List<Position> getAllPosition( ) {
		// TODO Auto-generated method stub
		return super.find("from Position");
	}

}
